﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.InteropServices.ComTypes;
using System.Text;
using System.Threading.Tasks;

namespace CL_VisionCommu_Test.Helper
{
    public class Helper
    {
        public enum RunState
        {
            Invalid,
            SystemRunning,
            SystemError,
            TestplanLoaded,
            TestplanReady,
            TestplanRunning,
            TestplanWaitForData,
            TestplanFinished,
            TestplanPause,
            TestplanBreakPoint,
            TestplanStepPause,
            TestplanStopped,
            TestplanDelayed
        }

        public enum ResultState
        {
            Invalid,
            Undefined,
            Error,
            Passed,
            Failed
        }

        public enum AliveState
        {
            Reset,
            Set
        }

        public enum OperationMode
        {
            Invalid,
            Unknown,
            Auto,
            Manual,
            Special,
            Step
        }

        public enum RunMode
        {
            None,
            Master,
            Slave
        }

        public class EnumHelper<T>
        {
            public static List<T> ToList()
            {
                return Enum.GetValues(typeof(T)).Cast<T>().ToList();
            }
        }
    }
}
